export class PostCatrgoryModel {
  id: number
  name: string

  constructor(id: number, name: string) {
    this.id = id
    this.name = name
  }
}

export class PostModel {
  id: number
  title: string
  category: string
  desc: string
  tags: Array<string>
  time: string
  isOutlink: boolean
  linkUrl: string

  constructor(
    id: number,
    title: string,
    category: string,
    desc: string,
    tags: Array<string>,
    time: string,
    isOutlink: boolean = false,
    linkUrl: string = '',
  ) {
    this.id = id
    this.title = title
    this.category = category
    this.desc = desc
    this.tags = tags
    this.time = time
    this.isOutlink = isOutlink
    this.linkUrl = linkUrl
  }
}
